-- 0-31个timer
local Timers = {}

function randomNumberStr()
    math.randomseed(os.time())
    return tostring(math.random(100000000000000000, 999999999999999999))
end

function println(value, ...)
    local result = join(",", value, ...)
    print("\n" .. tostring(result))
    -- local args = {...}
    -- for i, v in ipairs(args) do
    --     print(",", tostring(v))
    -- end
end

function println2(value, value2)
    print("\n" .. tostring(value) .. tostring(value2))
end

function print_table(table_data)
    if type(table_data) == "table" then
        print("{")
        for key, value in pairs(table_data) do
            if type(value) == "table" then
                print_table(value)
            end
            print("key=", key, ",value=", value)
        end
        print("}")
    end
end

function join(connector, ...)
    print("in join")
    local result = ""
    for i = 1, select("#", ...) do
        local arg = select(i, ...)
        if type(arg) == "table" then
            for k, v in pairs(arg) do
                result = result .. "," .. tostring(v)
            end
        else
            result = result .. "," .. tostring(arg)
        end
    end
    return string.sub(result, 2)
end

